Java Features
Table of Contents
Improved from C/C++
strings are not represented as null-terminated arrays1
Java doesn't suffer from this specific problem, since strings are not represented as null-terminated arrays. Array subscripts are checked as well, so it is not possible to access outside the bounds of an array in Java.
Footnotes:
1
The Practice of Programming page 14